package light.head.model.inv;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * 单据编号生成
 * @author yuleidian
 *
 */
@Entity
@Table
public class InvBillCode implements Serializable{
	private static final long serialVersionUID = 5586110524509466433L;
	private Integer code;			// 流水号
	private Integer bcc;			// 单据配置编号
	private String ymd;				// 日期（yyyMMdd）
	private Byte btype;				// 业务类型(1.进货订单，2.销货订单，3.入库单，4.出库，5.收款单，6.付款单，7.调拨单，8.零售单，9.零售退货单，10.销货退货，11.进货退货)
//	private Long st;				// 开始时间
//	private Long et;				// 结束时间
	private Integer number;			// 记录数(当天时间 在开始时间 和结束时间内 数量+1 ,否者就初始化开始时间,结束时间, number)
	
	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@Column
	public Integer getCode() {
		return code;
	}
	@Column
	public Integer getBcc() {
		return bcc;
	}
//	@Column
//	public Long getSt() {
//		return st;
//	}
//	@Column
//	public Long getEt() {
//		return et;
//	}
	@Column
	public Integer getNumber() {
		return number;
	}
	

	@Column(length = 20)
	public String getYmd() {
		return ymd;
	}
	
	@Column
	public Byte getBtype() {
		return btype;
	}
	
	
	
	public void setBtype(Byte btype) {
		this.btype = btype;
	}
	public void setYmd(String ymd) {
		this.ymd = ymd;
	}
	public void setCode(Integer code) {
		this.code = code;
	}
	public void setBcc(Integer bcc) {
		this.bcc = bcc;
	}
//	public void setSt(Long st) {
//		this.st = st;
//	}
//	public void setEt(Long et) {
//		this.et = et;
//	}
	public void setNumber(Integer number) {
		this.number = number;
	}

	
}
